﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package Init {
    import flash.events.*;
    import Engine.Init.*;
    import Display.*;

    public class UIInit extends InitializationAction {

        public static const INIT_ID:String = "UIInit";

        public function UIInit(){
            super(INIT_ID);
            addDependency(GlobalsInit.INIT_ID);
            addDependency(LocalizationInit.INIT_ID);
            addDependency(LocaleFontInit.INIT_ID);
            addDependency(ServiceInit.INIT_ID);
            _weight = 20;
        }
        override public function execute():void{
            var _local1:UI = new UI();
            GlobalEngine.zaspManager.trackTimingStart("UI_INIT");
            Global.player.setFakeFriend();
            if (Global.friendbar){
                Global.ui.m_friendBar.populateNeighbors(Global.friendbar);
                Global.ui.setFriendBarPos(Math.max((Global.friendbar.length - 15), 0));
            };
            GlobalEngine.zaspManager.trackTimingStop("UI_INIT");
            dispatchEvent(new Event(Event.COMPLETE));
        }

    }
}//package Init 
